package cz.idsv.web.mvc.model.dao;

import java.util.Collection;

import org.springframework.dao.DataAccessException;

import cz.idsv.web.mvc.model.entity.AddressEntity;



/**
 * Address DAO interface.
 * 
 * @author Jan Borzensky 
 */
public interface AddressDao {

    /**
     * Find address.
     */
    public Collection<AddressEntity> findAddress();
    
    /**
     * Saves address.
     */
    public void save(AddressEntity addressEntity);
    
    
    /**
     * Delete address.
     */
    public void delete(AddressEntity addressEntity);
    
    /**
     * Find address by id.
     */
    public AddressEntity findAddressById(Integer id) throws DataAccessException;
    /**
     * Find address by street.
     */
    public Collection<AddressEntity> findAddressByStreet(String streetName) throws DataAccessException;
    /**
     * Find address by city.
     */
    public Collection<AddressEntity> findAddressByCity(String cityName) throws DataAccessException;
    /**
     * Find address by streetNumber.
     */
    public Collection<AddressEntity> findAddressByStreetNumber(Integer streetNumber) throws DataAccessException;
    /**
     * Find address by postNumber.
     */
    public Collection<AddressEntity> findAddressByPostNumber(Integer postNumber) throws DataAccessException;
}

